package com.gjun.struts.resource;

import java.util.List;

import com.gjun.struts.bean.GjunMainTypeJson2Bean;
import com.gjun.struts.bean.GjunMainTypeJsonBean;
import com.gjun.struts.bean.GjunMaintype;

public interface GjunMainTypeResourceIf {
	public void saveMainType(GjunMaintype mt) throws Exception;

	public List<GjunMainTypeJsonBean> loadAllMainType();

	public boolean loadMainTypeByName(String name);

	public boolean loadMainTypeByNameAndId(String name, int id);

	public List<GjunMainTypeJson2Bean> loadAllMainTypes();

	public boolean delMainTypeById(int id) throws Exception;

	public GjunMaintype loadMainTypeById(int id);

	public boolean updateMainType(int id, String info, String typename,
			String filePath) throws Exception;
	
	public boolean updateMainTypeNewsStateToActive(int id) throws Exception;
	
	
	
}
